<template>
    <a :key='value' @click="turnTo">{{label}}</a>
</template>
<script>
export default {
    name:'moneySpan',
    props:{
        value:{
            type:Number,
            default:0.00,
        },
    },
    computed:{
        label(){
            let p = this.value.toFixed(2) + "元";
            if (this.value >= 10000)
                p = (this.value / 10000).toFixed(2) + "万元";
            if (this.value >= 100000000)
                p = (this.value / 10000 / 10000).toFixed(2) + "亿元";
            return p;
        }
    },
    methods:{
        turnTo(){

        }
    }
}
</script>
